Skip to content

Feat: numpy array parameters, step 1 (#220) - #263

Merged
b-re-w merged 2 commits into
developfrom
feat/tp-numpy
Oct 24, 2026
Merged

b-re-w merged 2 commits into
developfrom
feat/tp-numpy

Conversation

@b-re-w

@b-re-w b-re-w commented Oct 24, 2026

Copy link
Copy Markdown
Member

Refs #220 (step 1 of 2; step 2 is warnings and division).

Element-only numpy float64/int64 parameters take the buffer path (C-contiguous, 1-D, exact ndarray, else the object path); results are boxed as the interpreter's numpy scalar type via a run-time taint flag; pure functions deopt on a non-finite + - * result or an unproved int overflow so the interpreter emits numpy's warning; division, impure arithmetic on elements and stores of element values stay interpreted until step 2. Functions using the array as a whole object keep compiling with an opaque parameter (no regression, tests whole_sum/whole_attr/whole_pass). A numpy-derived value never becomes INT. Bool arrays: #261.

Red: new test_buffer_numpy.py 19 failed, 10 passed before implementation. Local 3.15t full suite: 1298 passed, 3 skipped. Benchmark compiled set identical to develop (test_the_benchmarks_compile_the_same_functions_as_before; benchmarks use no numpy).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant